from pydantic import BaseModel, Field


class M3u8Resource(BaseModel):
    uri: str = Field(..., description="资源链接")
    title: str = Field(..., description="视频标题")
    time_: int = Field(..., description="视频时长")
    author: str = Field(..., description="作者")


class YoutubeResource(BaseModel):
    url: str = Field(..., description="浏览器访问链接")
    uri: str = Field(None, description="资源链接")
    title: str = Field(None, description="视频标题")
    summary: str = Field(None, description="视频简介")
    author: str = Field(None, description="作者")
    partition_: str = Field(None, description="合集（分类）")
